home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1997 April / EnigmA AMIGA RUN 17 (1997)(G.R. Edizioni)(IT)[!][issue 1997-04][EAR-CD].iso / EARCD / comm / fido / GMS_1_1_85.lha / GMS / Rexx / GMS_deleteConfig.rexx < prev    next >
OS/2 REXX Batch file  |  1995-07-09  |  848b  |  50 lines

  1. /*
  2.  * $VER: GMS_DeleteConfig.rexx 1.0 (9.7.95)
  3.  *
  4.  */
  5.  
  6. options results
  7. signal on error
  8. signal on syntax
  9.  
  10. parse arg gms_line
  11.  
  12. if( ~show( 'l', "gms_mailer_rexx.library" ) ) then
  13. do
  14.    if( ~addlib( "gms_mailer_rexx.library", 0, -30, 0 ) )then
  15.    do
  16.       say "Could not open gms_mailer_rexx.library"
  17.       exit 10
  18.    end
  19. end
  20.  
  21. if gms_line == '' then signal Usage
  22.  
  23. call GMS_Mailer_System_Alloc('gms_mailer', gms_line, 'nonew')
  24.  
  25. call GMS_Mailer_Config_Delete('gms_mailer')
  26.  
  27. call GMS_Mailer_System_Free('gms_mailer')
  28.  
  29. call GMS_Mailer_FreeScriptData()
  30. exit 0
  31.  
  32. Usage:
  33.  
  34. say 'Usage: rx GMS_DeleteConfig[.rexx] <line num>'
  35.  
  36. call GMS_Mailer_FreeScriptData()
  37. exit 0
  38.  
  39. error:
  40. syntax:
  41.  
  42. error_text = GMS_Mailer_LastError()
  43.  
  44. if error_text = '' then error_text = rc ErrorText( rc )
  45.  
  46. say '| ***BREAK: error at' sigl error_text
  47.  
  48. call GMS_Mailer_FreeScriptData()
  49. exit rc
  50.